package com.Controller;
import com.Service.PraiseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import java.sql.SQLException;
@Controller
@RequestMapping("/praise")
public class PraiseController {
    @Autowired
    private PraiseService praiseService;
    @PostMapping("/add")
    @ResponseBody
    public void updatePraise(@RequestParam String number,@RequestParam String commentId) throws SQLException {
       praiseService.updatePraise(number,commentId);
    }
}
